/**
 * 数据
 */

import Directory from '../../../../temp/directory'

let data = [] // [{template, script, style}]

let domParser = new DOMParser()

for (let el of Directory) {
  let doc = domParser.parseFromString(el, 'text/html')
  let template = doc.querySelector('template')
  let script = doc.querySelector('script')
  let style = doc.querySelector('style')

  data.push({
    template: (template && template.innerHTML) || '',
    script: (script && script.innerHTML) || '',
    style: (style && style.innerHTML) || ''
  })
}

export default data
